import axios from "@/api/http";
export const getClaApi = () => {
  return axios({
    method: "get",
    url: "https://api-hmugo-web.itheima.net/api/public/v1/categories",
  });
};

export const getClaListApi = (query) => {
  return axios({
    method: "get",
    url: "https://api-hmugo-web.itheima.net/api/public/v1/goods/search",
    params: {
      query,
    },
  });
};
export const getDetailApi = (goods_id) => {
  return axios({
    method: "get",
    url: "https://api-hmugo-web.itheima.net/api/public/v1/goods/detail",
    params: {
      goods_id,
    },
  });
};
export const setCreate = (data) => {
  return axios({
    method: "post",
    url: "http://localhost:12345/api/order/create",
    data,
  });
};
